<div ng-include="sys_html('common/_header')"></div>
<style>
.fui-icon-group .fui-icon-col {
    margin: 0.1rem 0;
}
.fui-header:after {
	border-bottom: 0 solid #D9D9D9;
}
.fui-searchbar {padding-top:0.3rem;padding-bottom:0.3rem;margin-top:-2rem;height:auto;border-top-right-radius:1rem;border-top-left-radius:1rem;}
.searchbar .search-input input {
    height: 1.6rem;
}
.search-input i {
    line-height: 1.7rem;
}
.jylabels {
    display: inline;
    padding: 0 0.5rem;
    margin: 0.2rem;
    font-size: 0.55rem;
    line-height: 1.1rem;
    text-align: center;
    border-radius: 0.6rem;
}
.yuyue-duan {background:#fff;border: 0 solid #fff;border-radius: 4px;padding:0.1rem;margin:0.25rem 0.1rem;height:auto;width:auto;font-size:0.6rem;text-align:center}
.fui-header a.back:before {
	border-color: #fff
}
.fui-header a.back2:before {
	content: " ";
	display: inline-block;
	-webkit-transform: rotate(45deg);
	-ms-transform: rotate(45deg);
	transform: rotate(45deg);
	height: 0.5rem;
	width: 0.5rem;
	border-width: 0 0 2px 2px;
	border-color: #666;
	border-style: solid;
	position: relative;
	top:0;
}
.fui-icon-group .fui-icon-col .text {
    color: #999;
}
.fui-icon-group .fui-icon-col .text.active{
    color:red
}
.fui-list-inner .sorting {
    width: .2rem;
    height: .2rem;
    position: relative;
}
.fui-list-inner .sorting .icon {
    font-size: 0.85rem;
    position: absolute;
    -webkit-transform: scale(0.6);
    -ms-transform: scale(0.6);
    transform: scale(0.6);
}
.fui-list-inner .sorting .fa {
    font-size: 0.85rem;
    position: absolute;
    -webkit-transform: scale(0.6);
    -ms-transform: scale(0.6);
    transform: scale(0.6);
}
.fui-list-inner.desc .sorting .sanjiao1 {
    color: red
}

.fui-list-inner.asc .sorting .sanjiao2 {
    color: red
}
.fui-list-inner .sorting .icon-sanjiao1 {
    top: .15rem;
    left: 0;
}

.fui-list-inner .sorting .icon-sanjiao2 {
    top: -.15rem;
    left: 0;
}

.fui-list-inner.desc .sorting .icon-sanjiao1 {
    color: #ef4f4f
}

.fui-list-inner.asc .sorting .icon-sanjiao2 {
    color: #ef4f4f
}
</style>
<div class="fui-page fui-page-current page-goods-list" ng-if="pagedata.op=='main'">
		<div class="jy2-headertopbg">
			<div class="fui-header" style="background:none">
				<div class="fui-header-left">
					<a class="back" style="color:#fff" href="javascript:" ng-click="goback()"></a>
				</div>
				<div class="title bold" style="font-size:1rem;color:#fff">搜索服务</div>
				<div class="fui-header-right" style="padding-right:0.5rem;color:#fff">
					<i class="icon jinyunicon icon-fenxiang2" onclick="$('#showsharecover').modal();" style="font-size: 1rem;margin-right:10px"></i>
					<i class="icon jinyunicon icon-liaotian" ng-click="access_json('jy_merchfuwu/member.index/')" style="font-size: 1rem;"></i>
				</div>
			</div>
		</div>
		<div class="fui-searchbar bar" style="z-index: 0;">
					<div ng-class="{'searchbar':1,'searchbar-active':pagedata.searchbar ==1}" style="background:none;padding-bottom:0.2rem">
							<div style="position: relative;left:0;top:0;">
								<div class="search-input">
									<i id="searchsub" class="icon icon-sousuo1" ng-click="pagedata.getlist()"></i>
									<input type="search" placeholder="请输入商家、商品名称" class="search" ng-model="pagedata.params.keyword" style="text-align: left; color: #999; font-size:0.6rem;background:#fff;border-radius: 1rem;" />
								</div>
							</div>
					</div>
					<div class="row margin0">
							<div class="jylabels jylabel-f3f3f3" style="background-color:#fff;color:#fb9191" ng-click="pagedata.params={};pagedata.getlist();">重置筛选</div>
							<div ng-repeat="(k,v) in pagedata.searchkeyword" class="jylabels jylabel-f3f3f3" style="background-color:#fff" ng-click="pagedata.params.keyword=v;pagedata.getlist();">{{v}}</div>
					</div>
		</div>
		<!-- 滚动后出现 -->
		<div ng-if="showtopheader" class="fui-header searchtop" style="height:2.6rem;background:#fff">
			<div class="fui-header-left" style="height: 2.5rem;">
				<a class="back2" href="javascript:" ng-click="goback()"></a>
			</div>
			<div class="fui-header-input" style="top:0.1rem;right:0.5rem">
				<div class="searchbar searchbar-active" style="margin-left:1.6rem">
						<div class="search-input" style="margin-right:1.5rem">
							<i id="searchsub" class="icon icon-sousuo1" ng-click="pagedata.getlist()"></i>
							<input type="search" placeholder="请输入服务名称" class="search" ng-model="pagedata.params.keyword" style="text-align: left; color: #999; font-size:0.6rem;background:#f9f9f9;border-radius: 1rem;border: 0 solid #ddd;"/>
						</div>
				</div>
			</div>
			<div class="fui-header-right" style="padding-right:0.5rem;">
					<i class="icon jinyunicon icon-fenxiang2" onclick="$('#showsharecover').modal();" style="font-size: 1rem;margin-right:10px"></i>
					<i class="icon jinyunicon icon-liaotian" ng-click="access_json('jy_weishop/member.index/')" style="font-size: 1rem;"></i>
			</div>
		</div>
		<div class="fui-content" style="top:0">	
			<div ng-if="pagedata.shopset.open_tips==1" class="tips tips-yellow">
				<i class="fa fa-bullhorn"></i> [<red>温馨提示</red>]：{{pagedata.shopset.tips}}
			</div>
			<div class='fui-content-inner'>
				<div ng-if="!pagedata.loading && (!pagedata.list || pagedata.list.length<1)" class='content-empty' style="margin-top:0">
					<i class='icon icon-sousuo1'></i><br/>暂时没有任何服务
				</div>
				<div ng-include="sys_html('shop/_goodstwo')"></div>
				<div id="loading_show" class='infinite-loading'><span class='fui-preloader'></span><span class='text'> 正在加载...</span></div>
			</div>
		</div>
		<div ng-include="sys_html('common/_menu','','','jy_weishop')"></div>
</div>
<div class="fui-page fui-page-current page-goods-list" style="background: #fff;" ng-if="pagedata.op=='search'">
	<div class="fui-header">
			<div class="fui-header-input">
				<form method="post">
						<div class="searchbar searchbar-active" style="margin-left:0.2rem">
						<div class="search-input">
							<i class="icon jinyunicon icon-search" style="font-size: 0.8rem;"></i>
							<input type="search" id="search" ng-model="pagedata.params.keyword" placeholder="输入关键字..." value="">
						</div>
						</div>
				</form>
			</div>
			<div class="fui-header-right" data-nomenu="true">
				<a href="javascript:;" ng-click="access('main',made_query(pagedata.params));" style="padding:0.13rem 0.2rem 0 0.2rem"> 搜索</a>
			</div>
	</div>
	<div class="fui-content" style="margin-top:3rem;background:#fff">
				<div class="weui_cells_title" style="font-size: 0.7rem;"><i class="icon jinyunicon icon-hot" style="font-size: 0.7rem;"></i> 热门搜索</div>
				<div class="weui_cells">
					<div class="row margin0" style="margin-bottom:15px;line-height:">
							<div ng-repeat="(k,v) in pagedata.searchkeyword" class="jylabels jylabel-f3f3f3" ng-click="pagedata.params.keyword=v">{{v}}</div>
					</div>
				</div>
				<div ng-repeat="(value,data) in pagedata.province">
					<div class="weui_cells_title">{{value}}</div>
					<div class="weui_cells">
						<div class="row margin0">
							<div class="jy-3" ng-repeat="(city,data) in pagedata.province[value]">
									<div class="yuyue-duan" style="width:auto" ng-click="selectarea(value,city,'');pagedata.showarea = 0;">
											<div>{{city}}</div>
											<div class="clear"></div>
									</div>
							</div>
						</div>
					</div>
				</div>
	</div>
</div>
<div ng-include="sys_html('goods/common/_search','','','jy_weishop')"></div>
<div ng-include="sys_html('common/_gotop',true)"></div>
<div ng-include="sys_html('common/_share','','','jy_weishop')"></div>
<script>
console.log(scope.pagedata.params);
scope.pagedata.gotoitem=function(item){
	scope.access_json(item.active.url || '/goods.detail//id='+item.id);
}

scope.pagedata.showfilter=function(){
		$('#showfilter').modal();
}
scope.pagedata.getlist=function(order,showtype){
	if(order){
		scope.pagedata.params.order = order;
	}
	scope.pagedata.paramstype=showtype;
	scope.pagedata.isshowsearch=showtype;
	scope.tool.get_list('jy_merchfuwu/goods.index/getlist/',true);
	scope.$evalAsync();
}
//手机软键盘--搜索
$("body").keydown(function() {
    if (event.keyCode == "13") {
        $('#searchsub').click();
    }
});
</script>